home *** CD-ROM | disk | FTP | other *** search
- onClipEvent(enterFrame){
- yit = Math.floor(Math.random() * 471) + 30;
- if(this._x < -1500)
- {
- this._x = 900;
- this._y = _root.depth._y + yit;
- die = 1;
- this.gotoAndPlay(1);
- }
- if(this._x > 1500)
- {
- this._x = -400;
- this._y = _root.depth._y + yit;
- die = 1;
- this.gotoAndPlay(1);
- }
- this._x += _global.xgo;
- this._y += _global.ygo;
- if(die == 1)
- {
- if(_root.player.eat.hitTest(this.eat))
- {
- die = 0;
- reat = new Sound();
- reat.attachSound("magical bing");
- reat.start(0,1);
- this.gotoAndPlay("die");
- scoreworth = 50;
- multiplyer = 1;
- if(_root.tools.powerup1._currentframe > 10)
- {
- multiplyer = 2;
- }
- scoreity = Math.round(scoreworth * multiplyer);
- _root.tools.instascore.text = "+" + scoreity;
- _root.tools.instblock._alpha = 0;
- _global.scoreit = _global.scoreit * 1 + scoreity;
- if(_global.goballs < 2)
- {
- _global.goballs = _global.goballs + 1;
- }
- if(_global.goballs == 1)
- {
- _root.player.ongoball1._alpha = 255;
- }
- if(_global.goballs == 2)
- {
- _root.player.ongoball2._alpha = 255;
- }
- }
- }
- }
-